#include<iostream>
using namespace std;
typedef long long LL;
int n;
double x;
int main()
{
	LL ans = 1;
	cin >> n >> x;
	for (int i = 1; i <= n; i++) {
		ans *= 2;
	}
	double z = ans * x;
	//cout << "z==" << z << endl;
	LL zz = ans * x;
	if (z - 0.5 >= zz)zz++;
	cout << zz << endl;
	return 0;
}